<div data-ng-controller="ConsultaTurmaController">
	<div class="breadcrumb">
		<h4>Consulta de Turma</h4>
	</div>
    <form>
        <div id="searchFields" class="form-group">
            <label for="descricao">Descrição</label><input type="text" class="form-control" id="descricao" data-ng-model="pesquisa.descricao" />
        </div>
        <div class="form-group">
            <label>Disciplina </label>
            <div class="input-group">
                <ui-select ng-model="disciplina.selected">
                  <ui-select-match placeholder="Selecione ou procure uma disciplina na lista...">{{$select.selected.descricao}}</ui-select-match>
                  <ui-select-choices repeat="disciplina in disciplinas | filter: $select.search">
                    <span data-ng-bind-html="disciplina.descricao | highlight: $select.search"></span>
                  </ui-select-choices>
                </ui-select>
                <span class="input-group-btn">
                  <button data-ng-click="disciplina.selected = undefined" class="btn btn-default">
                    <span class="glyphicon glyphicon-trash"></span>
                  </button>
                </span>
            </div>
        </div>
        
        <div class="form-group">
            <label>Professor </label>
            <div class="input-group">
                <ui-select ng-model="professor.selected">
                  <ui-select-match placeholder="Selecione ou procure um professor na lista...">{{$select.selected.nome}}</ui-select-match>
                  <ui-select-choices repeat="professor in professores | filter: $select.search">
                    <span data-ng-bind-html="professor.nome | highlight: $select.search"></span>
                  </ui-select-choices>
                </ui-select>
                <span class="input-group-btn">
                  <button data-ng-click="professor.selected = undefined" class="btn btn-default">
                    <span class="glyphicon glyphicon-trash"></span>
                  </button>
                </span>
            </div>
        </div>
              
        <div class="form-group" style="display: inline-block; margin-right: 15px;">
                <label></label>
                <button class="btn btn-primary" type="button" data-ng-click="searchTurmas()">Pesquisar</button>
            </div>
    </form>
    <div id="searchResults" data-ng-show="turmas != null" data-ng-grid="gridOptions"></div>
</div>